package com.example.boot;

import com.example.client.RPCConsumer;
import com.example.service.UserService;

/**
 * @author lbq
 * @version 1.0
 * @date 2021/2/4 21:57
 */
public class ConsumerBoot {
    public static void main(String[] args) throws InterruptedException {
        RPCConsumer rpcConsumer = new RPCConsumer();
        UserService service = (UserService) rpcConsumer.createProxy(UserService.class);
        while (true) {
            String result = service.sayHello("zhangsan");
            System.out.println(result);
            Thread.sleep(2000);
        }
    }
}
